﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Model.Form
{
    /// <summary>
    /// 表单组件模型
    /// </summary>
    public class FormFieldModel
    {
        public field field = new field();
    }

    /// <summary>
    /// 字段集合
    /// </summary>
    public class field
    {
        /// <summary>
        /// 字段id
        /// </summary>
        public string id { get; set; } = string.Empty;

        /// <summary>
        /// 字段类型
        /// </summary>
        public string type { get; set; } = string.Empty;

        /// <summary>
        /// 字段项
        /// </summary>
        public options options { get; set; } = new options();

    }

    /// <summary>
    /// 字段项模型
    /// </summary>
    public class options
    {
        /// <summary>
        /// 字段唯一名称
        /// </summary>
        public string name { get; set; } = string.Empty;

        /// <summary>
        /// 字段显示名称
        /// </summary>
        public string label { get; set; } = string.Empty;

        /// <summary>
        /// 是否隐藏
        /// </summary>
        public bool hidden { get; set; }

        /// <summary>
        /// 是否禁用
        /// </summary>
        public bool disabled { get; set; }
    }
}
